#!/usr/bin/env python
PACKAGE = "lmpcc"

from dynamic_reconfigure.parameter_generator_catkin import *

gen = ParameterGenerator()

# ==================================== Parameters for the solver =====================================================

solv_constr = gen.add_group("Solver Stage Cost Parameters", "solver_constraints")
solv_constr.add("Wcontour",      double_t, 1, "Contour error weight", 0.1, 0.0, 100.0)
solv_constr.add("Wlag",          double_t, 1, "Lag error weight", 0.1, 0.0, 100.0)
solv_constr.add("Kv",            double_t, 1, "Forward velocity weight", 3.0, 0.0, 100.0)
solv_constr.add("Kw",            double_t, 1, "Angular velocity weight", 0.03, 0.0, 100.0)
solv_constr.add("Ws",            double_t, 1, "Weight on slack variable", 100.0, 0.0, 100000.0)
solv_constr.add("WR",            double_t, 1, "Weight on repulsive force", 0.1, 0.0, 50.0)
solv_constr.add("vRef",          double_t, 1, "Reference velocity", 1.2, 0.0, 2.0)
# ==================================== Parameters for limits enforcement =====================================================
limits = gen.add_group("Controller Options", "options")
limits.add("enable_output",      bool_t,   0, "Enable/Disable control output", False)
limits.add("loop_mode",          bool_t,   0, "Enable/Disable loop mode", False)
limits.add("n_iterations",       int_t,    1, "Number of KKT improvement iterations", 10, 1, 100)
limits.add("plan",               bool_t,   0, "Start LMPCC", False)
# ==================================== Parameters for search window =====================================================
search_window = gen.add_group("Search Window Options", "options")
search_window.add("window_size",     double_t,  1, "Seacrh window size", 0.2, 0.0, 10.0)
search_window.add("n_search_points", int_t,     1, "Number of seacrh points", 20, 1, 100)

exit(gen.generate(PACKAGE, "lmpcc", "Lmpcc"))

freeSpace